#include "stm32f10x.h"                
#include "Delay.h"
#include "Serial.h"
#include "LED.h"
uint8_t RxData;

int main(void)
{
	


	LED_Init();
	Serial_Init();
	
	while (1)
	{
		if (USART_GetFlagStatus(USART1,USART_FLAG_RXNE )== SET)
		{
			RxData = USART_ReceiveData(USART1);
		}
		if(RxData==0x59)
		{    
      LED_ON();

		}
		else if(RxData==0x4E)
		{
			LED_OFF();
		}
		else
		{
			;
		}
	}
}

